package org.example.gc;

import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

/**
 * -XX:+UseSerialGC  -Xms60m -Xmn20m -Xmx60m -XX:SurvivorRatio=3 -XX:+PrintGCDetails
 */
public class GcDemo {
    public static void main(String[] args) throws IOException {
        List<Object> list = new ArrayList<>();
        int count = 0;
        while (true) {
            System.in.read();
            System.out.println(++count);
            list.add(new byte[1024 * 1024 *1]);
        }
    }
}
